import { WeaSelect, WeaLocaleProvider,WeaHelpfulTip } from 'ecCom';
import { VisibleType } from '../../../../constants/excel';
const getLabel = WeaLocaleProvider.getLabel;
export default class FieldVisible extends React.Component {
    render() {
        if (this.props.isField) {
            return (
                <div className="ant-row">
                    <label>{getLabel('527411','字段显隐') }<WeaHelpfulTip ecId={`${this && this.props && this.props.ecId || ''}_WeaHelpfulTip@tcp5gr`}
                                style={{ marginLeft: '5px', verticalAlign: 'center', display: 'inline-block', lineHeight: '15px' }}
                                title={<div>
                                    <p>{getLabel('527412','字段较长时,需要设置为【自动换行】才能隐藏') }</p>
                                </div>}
                                placement="bottomLeft"
                            /></label>
                    <WeaSelect ecId={`${this && this.props && this.props.ecId || ''}_WeaSelect@27drcq`}
                        options={[{
                            key: VisibleType.display,
                            showname: getLabel('527413','显示') 
                        }, {
                            key: VisibleType.none,
                            showname: getLabel('527414','隐藏') 
                        }]}
                        {...this.props}
                    />
                </div>

            )
        }
        return null;
    }
}